1. Field of the Invention
The present invention relates in general to digital signal processing and in particular to systems and methods for decoding data applied in a compressed format in such digital processing systems.
2. Description of the Related Art
Modem signal processing systems, such as those found, for example, in commercial and consumer audio products, commonly received streamed data in compressed formats, thereby reducing bandwidth requirements on the data transport channels. This has been, at least in part, spurred by the use of the Internet as a medium for the distribution of audio and video content, in addition to the textual information that typified the early years of the Internet. Additionally, the traditional broadcast media, radio and television, for example, are introducing direct digital broadcast channels over which content will be streamed to consumers.
The use of coding techniques to compress the digital data prior to its being sent over the communication channel, reduces the bandwidth requirements that the channel must support. Conversely, a channel having a fixed bandwidth can accommodate more data streams, if the data streams are in a compressed format.
For example, the MPEG-4 audio standard provides a set of protocols for encoding audio signals. The protocols include a complete set of tools for coding low and high bit rate, natural and synthetic speech and music. A general audio coding portion of MPEG-4 is based on the MPEG-2 Advanced Audio enCoding (AAC) standard. AAC has become very popular because it preserves audio quality, making it advantageous, particularly for high quality audio systems.
Nonetheless, the properties of AAC complicate AAC decoder implementations. Memory requirements may be substantial, particularly in the case of multi-channel audio. Additionally, AAC provides a multiplicity of bit rates, tools, and profiles defined within the AAC specification. Additionally, the algorithms in the AAC definition have been designed to be implemented on a thirty-two-bit (32-bit) floating point engine. These characteristics of AAC impose stringent demands on the AAC decoder in an audio system by underlying MIPS and/or cost requirements complicated.
In particular, an AAC encoded audio stream may be compressed using a Huffman compression scheme selected from one of twelve Huffman codebooks (HCB) specified within the AAC. Moreover, the encoder may, dynamically, select the HCB depending on the characteristics of the audio source. Consequently, there is a need in the art for systems and methods to decode compressed audio bitstreams, such as those in accordance with the MPEG-4 AAC, and other encoding schemes, that operate within a selected MIPS budget and/or cost efficiency.
According to the principles of the present invention a method for decoding an encoded bitstream is disclosed. The method includes performing a two-table lookup. A first table is addressed in response to a first plurality of bits from the bitstream. An address into a second table is generated using a value in an entry in said first table accessed in the addressing step. A value (representing the decoded value corresponding to the codeword in the bitstream) in an entry in said second table at the address from the generating step is output.
The inventive concepts allow for the decoding of a bitstream constituting a sequence of encoded digital data, such as digital audio information encoded using variable-length codewords, such as Huffman encoding. Implementation of the inventive principles does not require an inordinate amount of look-up table memory or the execution of a burdensome number of additional instructions.